<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
</head>
<body>
    <script>
        var a = prompt("请输入第一个数");
        var b = prompt("请输入第二个数");
        a=Number(a);
        b=Number(b);
        document.write(a+b);
    </script>
</body>
</html>